package com.atguigu.a_sacnner;

import java.util.Scanner;

public class Demo {
    public static void main(String[] args) {
        //创建Scanner对象
        Scanner sc = new Scanner(System.in);

        //提示用户行为
        System.out.println("请您输入一句话 : ");

        //录入字符串
        //String str = sc.next();
        String str = sc.nextLine();
        System.out.println("str = " + str);
    }
}
